package com.tzbank.entity.backstage;

import com.tzbank.entity.BaseModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.annotations.Table;

import javax.persistence.Column;
import javax.persistence.Entity;
import java.io.Serializable;

/**
 * 用户表
 * @author XUZONGTIAN
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Entity(name = "mb_system_user")
@Table(appliesTo = "mb_system_user", comment = "用户表")
public class SystemUser extends BaseModel implements Serializable {

	private static final long serialVersionUID = 1674570664762475000L;

	/**
	 * 用户名
	 */
	@ApiModelProperty(value = "用户名")
	@Column(name = "user_name", columnDefinition = "VARCHAR(50) NOT NULL COMMENT '用户名'")
	private String userName;

	/**
	 * 用户密码
	 */
	@ApiModelProperty(value = "用户密码")
	@Column(name = "user_password", columnDefinition = "VARCHAR(50) NOT NULL COMMENT '用户密码'")
	private String userPassword;
	
	/**
	 * 手机号码
	 */
	@ApiModelProperty(value = "手机号码")
	@Column(name = "mobile", columnDefinition = "VARCHAR(50) NOT NULL COMMENT '手机号码'")
	private String mobile;

	/**
	 * 邮箱
	 */
	@ApiModelProperty(value = "邮箱")
	@Column(name = "email", columnDefinition = "VARCHAR(50) NOT NULL COMMENT '邮箱'")
	private String email;

	/**
	 * 是否有效: N-无效，Y-有效
	 */
	@ApiModelProperty(value = "N-无效，Y-有效")
	@Column(name = "valid", columnDefinition = "CHAR(1) NOT NULL DEFAULT 'Y' COMMENT 'N-无效，Y-有效'")
	private String valid;

	/**
	 * 是否删除 Y-已删除，N-未删除
	 */
	@ApiModelProperty(value = "是否删除 Y-已删除，N-未删除")
	@Column(name = "delete_flag", columnDefinition = "CHAR(1) NOT NULL DEFAULT 'N' COMMENT '是否删除 Y-已删除，N-未删除'")
	private String deleteFlag;

	/**
	 * 操作人
	 */
	@ApiModelProperty(value = "操作人")
	@Column(name = "operator", columnDefinition = "VARCHAR(50) NOT NULL COMMENT '操作人'")
	private String operator;

}
